{__NOLAYOUT__}
<!DOCTYPE html>
<html>
<head>

<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>酷学网</title>
<import type='css' file="Css.bdsstyle" />
<import type='js' file="Js.hm" />
<import type='js' file="Js.analytics" />
<import type='js' file="Js.logger" />

<import type='css' file="Css.common_s2" />
<import type='css' file="Css.libs" />
<import type='css' file="Css.jquery-ui-1" />
<import type='css' file="Css.select2" />

<import type='css' file="Css.WdatePicker" />
<import type='css' file="Css.ck_manage" />


<import type='js' file="Js.json2" />
<import type='js' file="Js.jquery-1" />
<import type='js' file="Js.jquery-ui-1" />
<import type='js' file="Js.jquery-ui-timepicker-addon" />
<import type='js' file="Js.select2-min" />
<import type='js' file="Js.public_v2" />
<import type='js' file="Js.jquery-1-8-2-min" />
<js href="__PUBLIC__/Js/layer-v2.1/layer/layer.js" />
<import type='js' file="Js.jquery-1-3-2-min" />

<!-- <js href="__PUBLIC__/ueditor/ueditor.config.js" />
<js href="__PUBLIC__/ueditor/ueditor.all.min.js" /> -->

<import type='js' file="Js.x" />
<import type='js' file="Js.hm" />
<import type='js' file="Js.jquery-common" />
<import type='js' file="Js.functions" />
<import type='js' file="Js.kk_header_www" />

<script src="__PUBLIC__/Js/jquery-1-8-0-min.js"></script>


</head>
<body>

<div id="adcode1044"></div>
<div id="adcode869"></div>


<script type="text/javascript">
    $(function(){
        $("#head_close").click(function(){
            $.ajax({
                url: "/shopping/removeSession",
                type: 'get',
                dataType:'text',
                success: function(){}
            });
        });

    });
</script>

<div id="header" class="koo_header">
    <div class="w980 matuo fc">
        <div class="logo fl w220 mt8"><a href="{:U('Index/Index/index')}"><img src="__ROOT__/Public/Images/logo_v2.png" alt="logo" height="49" width="187"></a></div>
        <div class="menus ft16 fl">
            <ul>
                <li><a href="{:U('Index/Index/index')}" class="  pl0">首页</a></li>
                <li><a href="http://www.koo.cn/findClass/0-0-1/">发现课程</a></li>
                <li><a href="http://www.koo.cn/teacher/0-0-0-0/">发现老师</a></li>
                <li><a href="http://www.koo.cn/userProduct/myProduct/1/horizontal" rel="nofollow">我要听课</a></li>
                <li><a href="{:U('Index/Course/index')}" class=" ">我要教课</a></li>
                <li><a href="http://bbs.koo.cn/" target="_blank">酷学社区</a></li>
            </ul>
        </div>
        <div class="user-tool fl">
            <!--登录前-->
            <if condition="$Think.session.uid eq ''">
            <ul class="">
                <li>
                    <a class="blue" href="javascript:void(0);" onclick="javascript:$('#userName').focus();return false;">
                        登录
                    </a>
                </li>
                <li class="spacer"></li>
                <li><a href="http://www.koo.cn/head/toRegist?next_page=http%3A%2F%2Fwww.koo.cn%2Fhead%2FtoLogin">注册</a></li>
            </ul>
            <!-- 登录前 E -->
            <!-- 登录后 S-->
            <else/>
            <dl class="fc">
                <dd class="shopcar">
                    <div class="car-icon has-menu" id="shop_car_top">
                        <span class="icons icons-car-black ft12"></span>
                        <i id="lhb_cart_num" style="position: relative;left: 40px;top: -15px;" >(1)</i>
                    </div>
                    <div class="car-content bg_white" id="buy_list">
                        <p style="display: none;" id="lhb_cart_lt1_h" class="ft12 center pt20 pb20 hide">购物车中还没有课程，赶紧<a href="http://www.koo.cn/findClass/0-0-1/" class="ml5 mr5">选购</a>吧！</p>
                        <div class="car-class ft12" id="lhb_cart_lt1"><ul><li class="fc"><a class="buy_car_img fl" href="http://www.koo.cn/course/5085"></a><h3 class="buy_car_title fl"><a href="http://www.koo.cn/course/5085" title="智鸣哥教你学英语之17考研长难句精讲班(寒假特训)">智鸣哥教你学英语之17考研长难句精讲班(寒假特训)</a></h3><div class="buy_car_pri fr"><span class="yellow fwb">￥399</span><br><a href="javascript:void(0);" onclick="theCartDel(67524588,5085,0)">×</a></div></li></ul><div class="count fc"><div class="text fl">共计1门课程<br>合计:<span class="yellow fwb">399</span>元</div><a class="btn btn_yellow3 fr ft14 mr5" href="http://www.koo.cn/shopping/gotoCart">去购物车结算</a></div></div>
                    </div>
                </dd>
                <dd>
                    <div class="message ">
                        <a href="http://www.koo.cn/customer/toMessage/1"><span class="icons icons-message ft12 mt5"><i id="lhb_msg_num" style="display:none;">(<strong></strong>)</i></span></a>
                    </div>
                </dd>
                <dd class="tools">
                    <div class="has-menu center">
                        <a href="http://www.koo.cn/liveStatistic/getLive">
                        </a><a href="http://www.koo.cn/liveStatistic/getLive"><img class="mt18 img-circular" src="__ROOT__{$userInfo['face']}" height="34" width="34"></a>


                    </div>
                    <div class="menu-content ft12">
                        <div class="item"><a href="http://www.koo.cn/liveStatistic/getLive" title="jiajiakatong" class="over-elips">{$userInfo['username']}</a></div>
                        <div class="item"><a href="http://www.koo.cn/userProduct/myProduct/1/horizontal"><em class="icons icons-lister"></em>我要听课</a></div>
                        <div class="item"><a href="{:U('Index/Course/index')}"><em class="icons icons-compute"></em>我要教课</a></div>
                        <div class="item"><a href="{:U('Index/Customer/index')}"><em class="icons icons-setting"></em>个人设置</a></div>
                        <div class="item"><a href="{:U('Index/Customer/password')}"><em class="icons icons-key"></em>密码修改</a></div>
                        <div class="item"><a id="head_close" href="{:U('Index/Login/logout')}" target="_self"><em class="icons icons-login-out"></em>退出</a></div>
                    </div>
                </dd>
            </dl>
            </if>
        </div>
        <!-- 登录后 E -->
    </div>
</div>
<!-- form login start -->
<!-- <form id="_loginForm" action="http://login.koo.cn/sso//login.do" method="post" style="display:none">
    <input name="_userName" id="_userName" type="hidden">
    <input name="_password" id="_password" type="hidden">
    <input name="_autoLogin" id="_autoLogin" value="on" type="hidden">
    <input name="_next_page" id="_next_page" type="hidden">
    <input name="_failPage" id="_failPage" value="http://www.koo.cn" type="hidden">
</form> -->
<!-- form login end -->
<!-- 用户登录框 -->

<div sj="mouseover" class="jhl_pop_box  jhl_pop  v3" id="pop_login_v2" style="display:none;">
    <div class="pop_tab">
        <ul>
            <li class="cur"><span>酷学网账号登录</span></li>
            <li><span>新东方网账号登录</span></li>
        </ul>
    </div>
    <div class="pop_ct">
        <!-- 酷学网账号登录  -->
        <form style="display: block;" action="" method="post">
            <dl class="login_box ft14 v3 pt10">
                <dt class="text gray99 "> 用新东方在线www.koolearn.com帐号可以直接登录</dt>
                <div class="warning hide" id="pnameError">
                    <em class="lhb_reg_ico2"></em>
                    <span class="red ft12" id="pnameErrorText"></span>
                </div>
                <dd class="sel ft14">
                    <!--<div class="inputs focus">-->
                    <div class="inputs">
                        <label for="userName" class="pos_r">
                            <em class="ioc-input-user"></em>
                            <em class="ioc-input-close" onclick="$('#puserName').val('');"></em>
                            <input class="input-username" maxlength="50" id="puserName" name="puserName" placeholder="请输入手机号或邮箱或用户名" onfocus="$(this).parents('.inputs').addClass('focus')" onblur="$(this).parents('.inputs').removeClass('focus');valid()" type="text">
                        </label>
                    </div>
                    <div class="infos hide" id="nameError">
                        <em class="lhb_reg_ico2"></em>
                        <span class="red" id="nameErrorText"></span>
                    </div>
                    <div class="infos hide" id="returnError">
                        <em class="lhb_reg_ico2"></em>
                        <span class="red">用户名或密码错误</span>
                    </div>
                </dd>
                <dd>
                    <!--<div class="inputs focus">-->
                    <div class="inputs ">
                        <label for="pwd" class="pos_r">
                            <em class="ioc-input-pwd"></em>
                            <em class="ioc-input-close" onclick="$('#ppassword').val('');"></em>
                            <input class="input-username" maxlength="16" id="ppassword" name="ppassword" placeholder="请输入密码" onfocus="$(this).parents('.inputs').addClass('focus')" onblur="$(this).parents('.inputs').removeClass('focus');valid()" type="password">
                        </label>
                    </div>
                    <div class="infos hide" id="ppwdError">
                        <em class="lhb_reg_ico2"></em>
                        <span class="red" id="ppwdErrorText"></span>
                    </div>
                </dd>
                <dt class="fc autologin">
                    <label><input id="pro" name="autoLogin" value="on" type="checkbox">
                        <span class="ml5 gray2" onclick="">自动登录</span>
                    </label>
                </dt>
                <dt class="mt10">
                    <a class="login-btn" href="#" submit="true" onclick="login()">登录 </a>
                </dt>
                <dt class="freetoreg w300 fc">
                    <a href="http://www.koo.cn/head/toRegist?next_page=http%3A%2F%2Fwww.koo.cn%2Fcustomer%2FtoUserInfo" class="fl">免费注册</a>
                    <a href="http://www.koo.cn/head/getBackPwd" class="blue fr">忘记密码?</a>
                </dt>
            </dl>
        </form>
        <form action="" method="post" style="display: none;" id="xdfForm">

        </form>

        <div class="third_login ft14">
            <div class="gray2 tal">其他合作平台账户登录：</div>
            <a href="javascript:void(0);" class="aoth_wx_v3" onclick="thirdLogin('weixin','add');" target="_self"></a>
            <a href="javascript:void(0);" class="aoth_qq_v3" onclick="thirdLogin('qq','add');" target="_self"></a>
            <a href="javascript:void(0);" class="aoth_weibo_v3" onclick="thirdLogin('sinaweibo','add');" target="_self"></a>
            <a href="javascript:void(0);" class="aoth_baidu_v3" onclick="thirdLogin('baidu','add');" target="_self"></a>
        </div>
    </div>
</div>





<script>
    // function wxlogin(){
    // //评论
    //     var d_url=document.location.href;
    //     var num = d_url.indexOf("/head/toLogin");
    //     if(num>0){
    //         d_url=d_url.replace("/head/toLogin","/findClass/0-0-1/");
    //     }
    //     var openUrl = "";//弹出窗口的url
    //     var iWidth=800; //弹出窗口的宽度;
    //     var iHeight=650; //弹出窗口的高度;
    //     var iTop = (window.screen.availHeight-30-iHeight)/2; //获得窗口的垂直位置;
    //     var iLeft = (window.screen.availWidth-10-iWidth)/2; //获得窗口的水平位置;
    //     window.open("http://login.koo.cn/sso/weixinProxyLogin.do?sceneId=1&next_page="+d_url,"aa","height="+iHeight+", width="+iWidth+", top="+iTop+", left="+iLeft,'toolbar=no,menubar=no,scrollbars=no,resizable=no,location=no,status=no');
    // }
    // $(function(){
    //     var loginStr="1";
    //     if(loginStr=="1"){
    //         //用户信息定时显示
    //         var msgNum=0;
    //         var msgTime=setInterval(function(){
    //             $.ajax({
    //                 type: "GET",
    //                 url: "/head/getMsg",
    //                 cache:false,
    //                 success: function(data){
    //                     if(data == 'error.user.kicked'){
    //                         window.location='http://www.koo.cn/head/toLogin?errCode=error.login.kicked';
    //                     }
    //                     else if(isNaN(parseInt(data)) || parseInt(data)==0){
    //                         $("#lhb_msg_num").hide();
    //                     }else{
    //                         msgNum=parseInt($("#lhb_msg_num strong").text());
    //                         $("#lhb_msg_num").show();
    //                         $("#lhb_msg_num strong").text(data);
    //                         $("#tool_popmsg").text(data);
    //                         if(msgNum<parseInt(data)){
    //                             $("#tool_msg").show();
    //                         }
    //                     }
    //                 }
    //             });
    //         },60000);

    //         //购物车数量
    //         theCartNum();
    //         //购物车详情列表
    //         theCartDetail();
    //     }
    // })


    function theCartNum(){
    //购物车数量
        $.ajax({
            type: "GET",
            url: "/shopping/cartCourseCount",
            cache:false,
            dataType: "json",
            success: function(data){
                if(isNaN(parseInt(data.result)) || parseInt(data.result)==0){
                    $("#lhb_cart_num").hide();
                }else{
                    $("#lhb_cart_num").show();
                    //$("#lhb_cart_num strong").text(data.result);
                    $("#lhb_cart_num").text("("+data.result+")");
                }
            }
        });
    }
    // function theCartDetail(){
    // //购物车详情列表
    //     $.ajax({
    //         type: "GET",
    //         url: "/shopping/cartCourseDetail",
    //         cache:false,
    //         dataType: "json",
    //         success: function(data){
    //             if(data.result.totalCount<=0){
    //                 $("#lhb_cart_lt1_h").show();
    //             }else{
    //                 $('#lhb_cart_lt1').empty();
    //                 var html = '';
    //                 $("#lhb_cart_lt1_h").hide();
    //                 html ="<ul>"
    //                 for (var i=0;i<data.list.length;i++){
    //                     html +='<li class="fc">'+
    //                             '<a class="buy_car_img fl" href="/course/'+ data.list[i].productId +'">'+
    //                             '<img src="'+ data.list[i].productIconUrlStr +'" onerror=\"this.src=\'http://images.koolearn.com/www/subject/kuxue/img/common/default_im.jpg\'\" width="56" height="35">'+
    //                             '</a>'+
    //                             '<h3 class="buy_car_title fl"><a href="/course/'+ data.list[i].productId +'" title="'+ data.list[i].productName +'">'+ data.list[i].productName +'</a></h3>'+
    //                             '<div class="buy_car_pri fr">'+
    //                             '<span class="yellow fwb">￥'+ data.list[i].productDiscountPrice +'</span><br>'+
    //                             '<a href="javascript:void(0);" onclick="theCartDel('+data.list[i].userId+','+data.list[i].productId+','+data.list[i].promotionId+')">×</a>'+
    //                             '</div>'+
    //                             '</li>';
    //                 }
    //                 html=html+'</ul><div class="count fc">'+
    //                         '<div class="text fl">'+
    //                         '共计'+ data.list.length +'门课程<br>'+
    //                         '合计:<span class="yellow fwb">'+ data.result.totalPrice +'</span>元'+
    //                         '</div>'+
    //                         '<a class="btn btn_yellow3 fr ft14 mr5" href="/shopping/gotoCart">去购物车结算</a>'+
    //                         '</div>';
    //                 $('#lhb_cart_lt1').html(html);
    //             }
    //         }
    //     });
    // }



    // function theCartDel(a,b,c){
    // //购物车列表删除
    //     $.ajax({
    //         type: "GET",
    //         url: "/shopping/cartCourseRemove?productIds="+ a +"_"+ b +"_"+ c,
    //         cache:false,
    //         dataType: "json",
    //         success: function(data){
    //             if(data.result.totalCount<=0){
    //                 $("#lhb_cart_num").hide();
    //                 $("#buy_list").hide();
    //                 $("#lhb_cart_lt1_h").show();
    //             }else{
    //                 $('#lhb_cart_lt1').empty();
    //                 var html = '';
    //                 $("#lhb_cart_num").show();
    //                 $("#buy_list").show();
    //                 $("#lhb_cart_lt1_h").hide();
    //                 html ="<ul>"
    //                 for (var i=0;i<data.list.length;i++){
    //                     html +='<li class="fc">'+
    //                             '<a class="buy_car_img fl" href="/course/'+ data.list[i].productId +'">'+
    //                             '<img src="'+ data.list[i].productIconUrlStr +'" onerror=\"this.src=\'http://images.koolearn.com/www/subject/kuxue/img/common/default_im.jpg\'\" width="56" height="35">'+
    //                             '</a>'+
    //                             '<h3 class="buy_car_title fl"><a href="/course/'+ data.list[i].productId +'" title="'+ data.list[i].productName +'">'+ data.list[i].productName +'</a></h3>'+
    //                             '<div class="buy_car_pri fr">'+
    //                             '<span class="yellow fwb">￥'+ data.list[i].productDiscountPrice +'</span><br>'+
    //                             '<a href="javascript:void(0);" onclick="theCartDel('+data.list[i].userId+','+data.list[i].productId+','+data.list[i].promotionId+')">×</a>'+
    //                             '</div>'+
    //                             '</li>';
    //                 }
    //                 html=html+'</ul><div class="count fc">'+
    //                         '<div class="text fl">'+
    //                         '共计'+ data.list.length +'门课程<br>'+
    //                         '合计:<span class="yellow fwb">'+ data.result.totalPrice +'</span>元'+
    //                         '</div>'+
    //                         '<a class="btn btn_yellow3 fr ft14 mr5" href="/shopping/gotoCart">去购物车结算</a>'+
    //                         '</div>';
    //                 $('#lhb_cart_lt1').html(html);
    //             }
    //             if($("#cartshopingtable").length>0){
    //                 location.reload(true) ;
    //             }
    //             theCartNum();
    //         }
    //     });
    // }



    var regUrl = /\/head\/(toRegist|toLogin|getBackPwd)/;
    function login(){
        var userName = $('#puserName').val();
        var password = $('#ppassword').val();

        //手机号
        if(userName == '')
        {
            $('#nameError').show();
            $('#nameErrorText').text('账号不能为空');
            return;
        }
        //密码
        if(password == '')
        {
            $('#ppwdError').show();
            $('#ppwdErrorText').text('密码不能为空');
            return;
        }
        var url = "http://login.koo.cn/sso//quickLogin.do?";
        if ( url.indexOf("?") == -1 ) {
            url += "?type=jsonp";
        }
        else {
            url += "&type=jsonp";
        }
        if($("#autoLogin").is(":checked"))
            url += "&autoLogin=on";

        $.ajax({
            url:url,
            dataType:'jsonp',
            data:{"userName":userName,"password":password},
            cache:false,
            success:function(data){
                if(data == 'success'){
                    $('#_userName').val(userName);
                    $('#_password').val(password);

                    if(regUrl.test(window.location)){
                        //window.location='http://www.koo.cn';
                        $('#_next_page').val('http://www.koo.cn');
                    }
                    else{
                        //window.location.reload();
                        $('#_next_page').val(window.location);
                    }
                    $('#_userName').attr('name','userName');
                    $('#_password').attr('name','password');
                    $('#_next_page').attr('name','next_page');
                    $('#_failPage').attr('name','failPage');
                    //自动登录
                    if($("#autoLogin").is(":checked")){
                        $('#_autoLogin').attr('name','autoLogin');
                    }
                    $('#_loginForm').submit();
                }
                if(data == 'error.login.userNameIsError'){
                    $('#returnError').show();
                    //  $('#pnameErrorText').text('用户名或密码错误');
                }
                if(data == 'error.login.timeInterval'){
                    $('#pnameError').show();
                    $('#pnameErrorText').text('账号在其他地方登录');
                }
                if(data == 'error.login.kicked'){
                    $('#pnameError').show();
                    $('#pnameErrorText').text('帐号在其他地方登录');
                }
                if(data == 'error.login.threepassError'){
                    $('#pnameError').show();
                    $('#pnameErrorText').text('连续三次密码错误，请5分钟后再登录');
                }
            },
            error: function() {

            }
        });
    }
    $('#puserName').on("focus",function(){reset1(1)});
    $('#ppassword').on("focus",function(){reset1(2)});
    function reset1(p){
        if(p == 1){
            $('#nameError').hide();
            $('#pnameError').hide();
            $('#preturnError').hide();
        }
        if(p == 2){
            $('#ppwdError').hide();
        }
    }

    function popLogin(){
    //用户登录框
        dialog({
            width:"460",
            selector:"#pop_login_v2",
            callback:{
                "btn":function(){
                    $(".zmask").on("click",function(){
                        $("#pop_login_v2").hide();
                        $(".zmask").remove();
                    })
                }
            }
        })
    }

    // $(function(){
    //     //登录切换  需要引入 http://images.koolearn.com/www/subject/script/common.js
    //     //popLogin();
    //     $("#pop_login_v2").ontabs(".pop_tab li",".pop_ct   form","cur","mouseover");


    // })

    // function thirdLogin(thirdType,type){
    //     var nextPage=$("input[name='next_page']").val();
    //     var kooNextPage='http://www.koo.cn/thirdLoginCon/callBack?bind='+type+'&nextPage='+nextPage;
    //     //var koo_next=encodeURIComponent(kooNextPage);
    //     var koo_next_url=base64_encode(kooNextPage);
    //     var url='http://login.koolearn.com/sso//requestToken.do?koo_next_page='+koo_next_url+'&type='+thirdType+'&f=www_third_denglu';
    //     location.href=url;
    // }



    function base64_encode(str){
        var c1, c2, c3;
        var base64EncodeChars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
        var i = 0, len= str.length, string = '';

        while (i < len){
            c1 = str.charCodeAt(i++) & 0xff;
            if (i == len){
                string += base64EncodeChars.charAt(c1 >> 2);
                string += base64EncodeChars.charAt((c1 & 0x3) << 4);
                string += "==";
                break;
            }
            c2 = str.charCodeAt(i++);
            if (i == len){
                string += base64EncodeChars.charAt(c1 >> 2);
                string += base64EncodeChars.charAt(((c1 & 0x3) << 4) | ((c2 & 0xF0) >> 4));
                string += base64EncodeChars.charAt((c2 & 0xF) << 2);
                string += "=";
                break;
            }
            c3 = str.charCodeAt(i++);
            string += base64EncodeChars.charAt(c1 >> 2);
            string += base64EncodeChars.charAt(((c1 & 0x3) << 4) | ((c2 & 0xF0) >> 4));
            string += base64EncodeChars.charAt(((c2 & 0xF) << 2) | ((c3 & 0xC0) >> 6));
            string += base64EncodeChars.charAt(c3 & 0x3F)
        }
        return string;
    }
</script>
<import type='css' file="Css.ck_base" />
<import type='css' file="Css.ck_headmaster" />
<link rel="stylesheet" type="text/css" href="__ROOT__/Public/Css/jquery.Jcrop.min.css" media="all">
<link rel="stylesheet" type="text/css" href="__ROOT__/Public/Js/uploadify-v3.1/uploadify.css" media="all">
<script type="text/javascript" src="__ROOT__/Public/Js/uploadify-v3.1/jquery.uploadify-3.1.min.js"></script>
<script type="text/javascript" src="__ROOT__/Public/Js/jquery.Jcrop.min.js"></script>
<script type="text/javascript" src="__ROOT__/Public/Js/ThinkBox/jquery.ThinkBox.js"></script>
<link rel="stylesheet" type="text/css" href="__ROOT__/Public/Js/ThinkBox/css/ThinkBox.css" media="all">


<div class="s_xxzl_tab">
  
    <dl class="postStep_2" style="width:900px;margin-left:100px">
            <dt style="width:800px">课程详情 - {$courseInfo[0]['coursename']}</dt>
            <!-- <dd class="i1">选择分类</dd>
            <dd class="i2">填写课程信息</dd>
            <dd class="i3">发布成功</dd> -->
    </dl>
</div>
<script>
    $(function(){
        $('ul.nav_kcgl > li').click(function(){
            $(this).addClass('here').siblings().removeClass('here');
        }).hover(function(){
            $(this).css({'background-color':'#F2F2F2'});
        },function(){
            $(this).css({'background-color':''});
        });
    });
</script>
<s class="clear"></s>       
<div class="pageContainer" style="border:1px solid #abadb3;width:1000px;">

 <!--   <section class="pageContent"> -->
    <if condition="$list neq '' ">
        <foreach name="list" item="vo">
        <!-- <li id='edit' style='list-style:none;width:980px;height:100px;margin:10px;border:1px solid red'><input type='hidden' name='courseid' value='{$vo['courseid']}'>开始时间：<p id=''style='height:30px;margin:10px 0px;'>{$vo['starttime']}-{$vo['endtime']}本节课程介绍：<p id='' style='height:30px;margin:5px 0px;'>{$vo['content']}" -->
        <li style='list-style:none;width:960px;height:50px;margin:10px;border:1px solid red;padding:10px'><input type='hidden' name='courseid' value='{$vo['courseid']}'><input type='hidden' name='courselistid' value='{$vo['id']}'><div style='height:25px'><button type='button' id='edit' style='width:100px;background-color:#5bc79d'>编辑</button>&nbsp;&nbsp;&nbsp;<span style='font-size:14px;'>时间：</span><span style='font-size:14px;margin:10px'>{$vo['starttime']|date='Y-m-d H:i',###}-{$vo['endtime']|date='H:i',###}</span></div><a id='delete' href='' onclick='return confirm(确定删除?);'><button type='button' style='width:100px;background-color:#5bc79d'>删除</button></a>&nbsp;&nbsp;&nbsp;<span style='font-size:14px'>本节课程介绍：</span><span style='margin:10px;'>{$vo['content']}</span></li>


        </foreach>
    </if>

</div>       
   <!--  </section> -->
    <form id="ajax" action="" name='ajax' method="post">
            <div id='adddata' style='width:980px;height:100px;margin:10px auto;'><input id='courseid' type='hidden' name='courseid' value="{$courseid}">开始时间：<input name='starttime' id='starttime' type='datetime-local' value='' style='width:180px;height:20px;margin:10px 0px;'>&nbsp;结束时间：<input name='endtime' id='endtime' type='datetime-local' value='' style='width:180px;height:20px;margin:5px 0px;'>&nbsp;<button type='button' id='addcourse' style='margin-left:200px;width:60px;height:40px;background-color:#5bc79d'>添加一节</button></br>本节课程介绍：<input name='content' id='content' type='text' value='' style='width:730px;height:30px;margin:5px 0px;font-size:14px;text-indent:5px'></div>
        </form>

    <!-- =E pageContent -->

    <!-- =E pageContainer -->

   
<script type="text/javascript">
     $(function(){
        $('#addcourse').click(function(event) {
             // $(".pageContainer").append("<li id='edit' style='list-style:none;width:980px;height:100px;margin:10px;border:1px solid red'><input type='hidden' name='courseid' value='{$vo['courseid']}'>开始时间：<p id=''style='height:30px;margin:10px 0px;'>{$vo['starttime']}-{$vo['endtime']}课程详情：<p id='' style='height:30px;margin:5px 0px;'>{$vo['content']}"); 
            //阻止表单默认提交事件
                event.preventDefault();
            var info = $("form[name='ajax']").serialize();
            $.ajax({
                type: "post",
                async: false, //同步执行
                url: "{:U('Index/Course/add')}",
                data: info,
                dataType:'json',
                // contentType: 'application/x-www-form-urlencoded; charset=UTF-8',
        
                // traditional:true,
                success:function (msg) {
                    if(msg == "请设置合理的时间"){
                        alert(msg);
                    }else if(msg == "请填写本节课程介绍"){
                        alert(msg);
                    }else if(msg == "已超出你设置的课程总节数，若想增加，请返回修改课程信息"){
                        alert(msg);
                    }else{
                        // var a = "<li style='list-style:none;width:960px;height:50px;margin:10px;border:1px solid red;padding:10px'><input type='hidden' name='courseid' value='$courseid'><input type='hidden' name='courselistid' value='$id'><div style='height:25px'><button type='button' id='edit' style='width:100px;background-color:#5bc79d'>编辑</button>&nbsp;&nbsp;&nbsp;<span style='font-size:14px;'>时间：</span><span style='font-size:14px;margin:10px'>$start - $end</span></div><a id='delete' onclick='return confirm('确定删除?')?location.href='127.0.0.1/kx/index.php/Index/Course/deletelist/id/$id':'''>删除</a>&nbsp;&nbsp;&nbsp;<span style='font-size:14px'>本节课程介绍：</span><span style='margin:10px;'>$content</span></li>";
                        $(".pageContainer").append(msg); 
                        // $("#courseid").attr('value',''); 
                        $("#starttime").attr('value',''); 
                        $("#endtime").attr('value',''); 
                        $("#content").attr('value',''); 
                       
                    }


                },
                    
                error: function () {
                    alert("网络连接错误，请稍后再试");
                }
            });
        });  

        // $("#delete").live('click',function(){ 
        //   $(this).parent().remove();
        // }); 

    });


</script>

<!-- <js href="__PUBLIC__/Js/ckpv1.js" /> -->
<!-- <img style="display:none" src="__PUBLIC__/Css/ckpage.php" width="0" height="0"> -->

<!-- <js href="__PUBLIC__/Js/WdatePicker.js" /> -->
<js href="__PUBLIC__/Js/jquery-drag.js" />


<script>
    var CourseID = 165667,
        SID = 4013097,
        ExpiryTime = "2018-02-22",
        IsAuthorize = 0,    //任命发课
        IsTeacher = 0,  //1V1老师安排课程
        HasBuyer = 1,   //是否已有用户购买
        IsQuote = false,    //是否可以引用外部影频
        Course1V1 = false,  //1对1课程
        Individuation = 0,  //个性化学习-是否开启
        Cost  = 0,  //课程价格
        GID = '';   //个性化学习-课程归属分类
    var IsTeacherHelper = 0;
    var CateRoute = '';
    var Live = 0,
        Offline = 0,
        _t = "1457404529|214e32d688380f2a9c5d5d17924107c0";
    //判断数据保全显示条件
    var SaveDisplay = 'none';
    if (Cost > 0) {
        SaveDisplay = 'block';
    }
</script>
<!-- <script src="./courseContent_files/courseware.js" type="text/javascript"></script>
<script src="./courseContent_files/detail.dev.js" type="text/javascript"></script> -->
<js href="__PUBLIC__/Js/courseware.js" />
<js href="__PUBLIC__/Js/detail-dev.js" />

<script>
// $(function(){
//     $("input:checkbox[name='save_flag']").live('click', function(){
//         if ($(this).attr('checked') != 'checked') {
//            var boxy = $.ckBoxy({
//                 title:'操作提示',
//                 content:'<div style="padding:20px"><div class="f14 tc" style="line-height:24px;"><img class="mr5 vm" src="http://res.ckimg.com/sites/www/v2/images/public/ico_warning_16x16.png" alt=""><span class="c_666">数据保全服务是一项保护数字作品版权的免费服务。取消勾选并保存该节课之后，将无法再次申请。</span></div><div class="c_333 mt30 f14 tc">你确定要取消勾选吗？</div><div class="tc mt30"><a href="#" class="n_btn38g mr20 sureBtn"><span>确定</span></a><a href="#" class="n_btn38gr_b cancelBtn"><span>取消</span></a></div></div>',
//                 width:408,
//                 height:270,
//                 callback:function(){
//                     $("#fe_dialogBox").find("a.sureBtn").unbind().bind('click', function(){
//                         boxy.cancel();
//                         return true;
//                     });
//                     $("#fe_dialogBox").find("a.cancelBtn").unbind().bind('click', function(){
//                         boxy.cancel();
//                         $("input:checkbox[name='save_flag']").attr('checked', 'checked');
//                     });
//                 }
//             });
//         }
//     });
// });
</script>

<!-- <div class=" koo_bg_gray pt20">
    <div class="w980 mauto">
        <div class="copy-right w980 mauto ft14">
            <ul>
                <li><a href="http://www.koo.cn/gb/aboutus/" rel="nofollow">关于我们</a></li>
                <li><a href="http://www.koo.cn/gb/join/" rel="nofollow">人员招聘</a></li>
                <li><a href="http://www.koo.cn/gb/contact/" rel="nofollow">联系我们</a></li>
                <li><a href="http://www.koo.cn/help/learn/1/" rel="nofollow">帮助中心</a></li>
                <li class="info gray w320">
                    <p>酷学网&nbsp; 收获每一课 京ICP备05067669号-4</p>
                    <p>北京新东方教育科技（<span title="14-wwwb">集团</span>）有限公司 版权所有</p>
                </li>
            </ul>
        </div>
    </div>
</div> -->
    <!--[if IE]>
    <script type="text/javascript" src="http://images.koolearn.com/www/subject/kuxue/js/jquery.placeholder.js"></script>

    <![endif]-->
    <!--[if lt IE 7]>
    <script type="text/javascript" src="http://images.koolearn.com/www/subject/script/json2.min.js"></script>

    <![endif]-->

    <!-- Baidu Button BEGIN -->
    <!--<script src="customer_files/bds_s_v2.js" type="text/javascript" id="bdshare_js" data="type=slide&amp;img=0&amp;pos=right&amp;uid=324170"></script>-->
    <!--<import type='js' file="Js.bds_s_v2" />-->


    <import type='js' file="Js.koolearnCollection" />
    <!-- <import type='js' file="Js.kuxueConf" /> -->
    <import type='js' file="Js.kuxue-tongji" />
    
    <import type='js' file="Js.cookie" />

   <script>
    //     $(function(){
    //         $('.zb_lst2 li:nth-child(3n)').css('margin-right','0');
    //         hrefIdCookie(["a_id","kid"]);
    //     })
 </script>






<div id="koo-go-top" class="">
    <a href="http://weibo.com/koocn" class="weibo"></a>
    <a href="javascript:void(0);" class="weixin pos_r"><img src="__ROOT__/Public/Images/towcode.png" alt="" height="220" width="231"></a>
    <a href="http://bbs.koo.cn/f-86-1.html" class="message"></a>
    <a href="http://www.koo.cn/app" class="telphone"></a>
    <a href="javascript:void(0);" target="_blank" onclick="doyoo.util.openChat('g=10055922&amp;command=robotChat'); return false;" class="aq"></a>
    <a href="javascript:void(0);" onclick="return false" class="to-top  cursor" style="display: none;"></a>
</div>
<div style="position: fixed; top: 120px; right: 5px; color: rgb(0, 0, 0); font-size: 12px;" id="doyoo_panel">

</div>
<!-- <div style="background: transparent url(&quot;http://static.soperson.com/131221/../default/images/monitor/m_bg_1.gif?131127&quot;) no-repeat scroll 0% 0%; width: 429px; height: 196px; position: fixed;" id="doyoo_monitor">
    <div id="doyoo_mon_innner" style="position:relative;width:100%;height:100%;-webkit-transform: translateZ(0px)">
        <div style="cursor: move;" id="doyoo_mon_head">在线客服</div>
        <div id="doyoo_mon_main">同学您好，目前新旧系统交替，可能无法及时回复您的对话，如有问题可拨打4006762300按2咨询，给您造成的不便，请谅解！</div>
        <div id="doyoo_mon_foot">
            <a style="background-image: url(&quot;http://static.soperson.com/131221/../default/images/monitor/acc_sc.gif?131127&quot;);" id="doyoo_mon_accept" class="doyoo_mon_btn" href="javascript:;" onclick="doyoo.util.openChat();doyoo.util.accept();return false;"></a>
            <a style="background-image: url(&quot;http://static.soperson.com/131221/../default/images/monitor/phone_sc.gif?131127&quot;); display: none;" id="doyoo_mon_phone" class="doyoo_mon_btn" href="javascript:;" onclick="doyoo.util.openPhone();doyoo.util.accept();return false;"></a>
            <div style="background-image: url(&quot;http://static.soperson.com/131221/../default/images/monitor/dn_sc.gif?131127&quot;);" id="doyoo_mon_refuse" class="doyoo_mon_btn">

            </div>
        </div>
    </div>
    <div id="doyoo_mon_closer">

    </div>
</div> -->
<!-- <div id="doyoo_share" style="">

    <iframe src="about:blank" id="shareWrapper"></iframe>
</div> -->

<img id="uuidimg" src="__ROOT__/Public/Images/__ktm.gif">

</body>
</html>
<script type="text/javascript">
    $(function(){
        //上传头像(uploadify插件)
        $("#user-pic").uploadify({
            'queueSizeLimit' : 1,
            'removeTimeout' : 0.5,
            'preventCaching' : true,
            'multi'    : false,
            'swf'           : '__ROOT__/Public/Js/uploadify-v3.1/uploadify.swf',
            'uploader'      : "{:U('Index/Course/uploadImg')}",
            'buttonText'    : '<i class="userup-icon"></i>上传头像',
            'width'         : '200',
            'height'        : '200',
            'fileTypeExts'  : '*.jpg; *.png; *.gif;',
            'formData' :    { 'uid' : '{$Think.session.uid}' },
            'onUploadSuccess' : function(file, data, response){
                //调试语句
                $('#isteacher').val(1);
                
                console.log(data);

                
                var data = $.parseJSON(data);
                
                if(data['status'] == 0){
                    $.ThinkBox.error(data['info'],{'delayClose':3000});
                    return;
                }
                var preview = $('.upload-area').children('#preview-hidden');
                preview.show().removeClass('hidden');
                //两个预览窗口赋值
                $('.crop').children('img').attr('src',data['path']+'?random='+Math.random());
                //隐藏表单赋值
                $('#img_src').val(data['path']);
                //绑定需要裁剪的图片
                var img = $('<img />');
                preview.append(img);
                preview.children('img').attr('src',data['path']+'?random='+Math.random());
                var crop_img = preview.children('img');
                crop_img.attr('id',"cropbox").show();
                var img = new Image();
                img.src = data['path']+'?random='+Math.random();
                //根据图片大小在画布里居中
                img.onload = function(){
                    var img_height = 0;
                    var img_width = 0;
                    var real_height = img.height;
                    var real_width = img.width;
                    if(real_height > real_width && real_height > 200){
                        var persent = real_height / 200;
                        real_height = 200;
                        real_width = real_width / persent;
                    }else if(real_width > real_height && real_width > 200){
                        var persent = real_width / 200;
                        real_width = 200;
                        real_height = real_height / persent;
                    }
                    if(real_height < 200){
                        img_height = (200 - real_height)/2;
                    }
                    if(real_width < 200){
                        img_width = (200 - real_width)/2;
                    }
                    preview.css({width:(200-img_width)+'px',height:(200-img_height)+'px'});
                    preview.css({paddingTop:img_height+'px',paddingLeft:img_width+'px'});
                }
                //裁剪插件
                $('#cropbox').Jcrop({
                    bgColor:'#333',   //选区背景色
                    bgFade:true,      //选区背景渐显
                    fadeTime:1000,    //背景渐显时间
                    allowSelect:false, //是否可以选区，
                    allowResize:true, //是否可以调整选区大小
                    aspectRatio: 1,     //约束比例
                    minSize : [100,100],//可选最小大小
                    boxWidth : 200,     //画布宽度
                    boxHeight : 200,    //画布高度
                    onChange: showPreview,//改变时重置预览图
                    onSelect: showPreview,//选择时重置预览图
                    setSelect:[ 0, 0, 100, 100],//初始化时位置
                    onSelect: function (c){ //选择时动态赋值，该值是最终传给程序的参数！
                        $('#x').val(c.x);//需裁剪的左上角X轴坐标
                        $('#y').val(c.y);//需裁剪的左上角Y轴坐标
                        $('#w').val(c.w);//需裁剪的宽度
                        $('#h').val(c.h);//需裁剪的高度
                  }
                });
                //提交裁剪好的图片
                $('.save-pic').click(function(){
                    if($('#preview-hidden').html() == ''){
                        $.ThinkBox.error('请先上传图片！');
                    }else{
                        //由于GD库裁剪gif图片很慢，所以长时间显示弹出框
                        $.ThinkBox.success('图片处理中，请稍候……',{'delayClose':30000});
                        $('#pic').submit()
                    }
                });
                //重新上传,清空裁剪参数
                var i = 0;
                $('.reupload-img').click(function(){
                    $('#preview-hidden').find('*').remove();
                    $('#preview-hidden').hide().addClass('hidden').css({'padding-top':0,'padding-left':0});
                });
            }
        });
        //预览图
        function showPreview(coords){
            var img_width = $('#cropbox').width();
            var img_height = $('#cropbox').height();
              //根据包裹的容器宽高,设置被除数
            var rx = 100 / coords.w;
            var ry = 100 / coords.h;
              $('#crop-preview-100').css({
                width: Math.round(rx * img_width) + 'px',
                height: Math.round(ry * img_height) + 'px',
                marginLeft: '-' + Math.round(rx * coords.x) + 'px',
                marginTop: '-' + Math.round(ry * coords.y) + 'px'
              });
              rx = 60 / coords.w;
              ry = 60 / coords.h;
              $('#crop-preview-60').css({
                width: Math.round(rx * img_width) + 'px',
                height: Math.round(ry * img_height) + 'px',
                marginLeft: '-' + Math.round(rx * coords.x) + 'px',
                marginTop: '-' + Math.round(ry * coords.y) + 'px'
              });
        }
    })

</script>


<script type="text/javascript">
    $(function(){
        //上传封面(uploadify插件)
        $("#user-pic1").uploadify({
            'queueSizeLimit' : 1,
            'removeTimeout' : 0.5,
            'preventCaching' : true,
            'multi'    : false,
            'swf'           : '__ROOT__/Public/Js/uploadify-v3.1/uploadify.swf',
            'uploader'      : "{:U('Index/Course/uploadImgCourse')}",
            'buttonText'    : '<i class="userup-icon1"></i>上传封面',
            'width'         : '315',
            'height'        : '200',
            'fileTypeExts'  : '*.jpg; *.png; *.gif;',
            'formData' :    { 'uid' : '{$Think.session.uid}' },
            'onUploadSuccess' : function(file, data, response){
                //调试语句
               $('#ispicture').val(1);
                console.log(data);
                
                var data = $.parseJSON(data);
                
                if(data['status'] == 0){
                    $.ThinkBox.error(data['info'],{'delayClose':3000});
                    return;
                }
                var preview = $('.upload-area1').children('#preview-hidden1');
                preview.show().removeClass('hidden1');
                //两个预览窗口赋值
                $('.crop1').children('img').attr('src',data['path']+'?random='+Math.random());
                //隐藏表单赋值
                $('#img_src1').val(data['path']);
                //绑定需要裁剪的图片
                var img = $('<img />');
                preview.append(img);
                preview.children('img').attr('src',data['path']+'?random='+Math.random());
                var crop_img = preview.children('img');
                crop_img.attr('id',"cropbox1").show();
                var img = new Image();
                img.src = data['path']+'?random='+Math.random();
                //根据图片大小在画布里居中
                img.onload = function(){
                    var img_height = 0;
                    var img_width = 0;
                    var real_height = img.height;
                    var real_width = img.width;
                    if(real_height > real_width && real_height > 200){
                        var persent = real_height / 200;
                        real_height = 200;
                        real_width = real_width / persent;
                    }else if(real_width > real_height && real_width > 315){
                        var persent = real_width / 315;
                        real_width = 315;
                        real_height = real_height / persent;
                    }
                    if(real_height < 200){
                        img_height = (200 - real_height)/2;
                    }
                    if(real_width < 315){
                        img_width = (315 - real_width)/2;
                    }
                    preview.css({width:(315-img_width)+'px',height:(200-img_height)+'px'});
                    preview.css({paddingTop:img_height+'px',paddingLeft:img_width+'px'});
                }
                //裁剪插件
                $('#cropbox1').Jcrop({
                    bgColor:'#333',   //选区背景色
                    bgFade:true,      //选区背景渐显
                    fadeTime:1000,    //背景渐显时间
                    allowSelect:false, //是否可以选区，
                    allowResize:true, //是否可以调整选区大小
                    aspectRatio: 1.57,     //约束比例
                    minSize : [145,92],//可选最小大小
                    boxWidth : 400,     //画布宽度
                    boxHeight : 200,    //画布高度
                    onChange: showPreview,//改变时重置ss预览图
                    onSelect: showPreview,//选择时重置预览图
                    setSelect:[ 0, 0, 145, 92],//初始化时位置
                    onSelect: function (c){ //选择时动态赋值，该值是最终传给程序的参数！
                        $('#x1').val(c.x);//需裁剪的左上角X轴坐标
                        $('#y1').val(c.y);//需裁剪的左上角Y轴坐标
                        $('#w1').val(c.w);//需裁剪的宽度
                        $('#h1').val(c.h);//需裁剪的高度
                  }
                });
                //提交裁剪好的图片
                $('.save-pic1').click(function(){
                    if($('#preview-hidden1').html() == ''){
                        $.ThinkBox.error('请先上传图片！');
                    }else{
                        //由于GD库裁剪gif图片很慢，所以长时间显示弹出框
                        $.ThinkBox.success('图片处理中，请稍候……',{'delayClose':30000});
                        $('#pic1').submit()
                    }
                });
                //重新上传,清空裁剪参数
                var i = 0;
                $('.reupload-img1').click(function(){
                    $('#preview-hidden1').find('*').remove();
                    $('#preview-hidden1').hide().addClass('hidden1').css({'padding-top':0,'padding-left':0});
                });
            }
        });
        //预览图
        function showPreview(coords){
            var img_width = $('#cropbox1').width();
            var img_height = $('#cropbox1').height();
              //根据包裹的容器宽高,设置被除数
            var rx = 146 / coords.w;
            var ry = 92 / coords.h;
              $('#crop-preview-1001').css({
                width: Math.round(rx * img_width) + 'px',
                height: Math.round(ry * img_height) + 'px',
                marginLeft: '-' + Math.round(rx * coords.x) + 'px',
                marginTop: '-' + Math.round(ry * coords.y) + 'px'
              });
              rx = 60 / coords.w;
              ry = 60 / coords.h;
              $('#crop-preview-601').css({
                width: Math.round(rx * img_width) + 'px',
                height: Math.round(ry * img_height) + 'px',
                marginLeft: '-' + Math.round(rx * coords.x) + 'px',
                marginTop: '-' + Math.round(ry * coords.y) + 'px'
              });
        }
    })

</script>
